﻿
namespace Cos.Module.CMS.NHibernate.Test
{
    using Cos.Core.NHibernate;
    using Cos.Core.NHibernate.Tests;

    using NUnit.Framework;

     [TestFixture]
    public class ElementDataModelFixture : ModuleFixtureBase
    {
        [Test]
        public void CanMapElementDataModel()
        {
            new PersistenceSpecification<ElementDataModel>(Session)
                .CheckProperty(x => x.ElementFile, "file")
                .CheckProperty(x => x.ElementFilePreview, "file preview")
                .CheckProperty(x => x.ElementValue, "value")
                .CheckProperty(x => x.ElementValuePreview, "value preview")
                .CheckProperty(x => x.PageId, this.Page.Id)
                .CheckProperty(x => x.PartId, this.Part.Id)
                .VerifyTheMappings();
        }
    }
}
